$('.editinplace').editable('/category/saveajax/', {
	indicator : '正在保存...',
	tooltip   : '点击修改...',
	onblur    : 'submit' 
});
/**
 * ajax delete
 * @param catid
 * @param url
 * @return
 */
function ajaxOp(op,catid,url)
{
	if(op=='delete')
	{
		if(window.confirm('单击“确定”继续删除操作。单击“取消”停止。\r\n\n注：删除操作将删除该栏目所有相关内容，请慎重。'))
	    {
	        url += Math.random();
	        $.get(url, function(data){
				data = $.trim(data);
	        	 if(data=='true')
	        	 {
	        		 $('#tr_'+catid).remove();
	        	 }
	            else
	            {
	            	alert('该栏目下面还有子栏目不可删除，若想删除请先删除其子栏目。');
	            }
	        });
	    }
	}
	else if(op=='clear')
	{
		if(window.confirm('单击“确定”继续清空操作。单击“取消”停止。\r\n\n注：清空操作将删除该栏目所有相关内容，请慎重。'))
	    {
	        url += Math.random();
	        $.get(url, function(data){
	        		 $.get(url, function(data){$('#tr_'+catid).children('td').eq(6).html('0');});
	        });
	    }
	}
	else if(op=='ismenu')
	{
		var id="ismenu_"+catid;
		var imgUrl = $('#'+id)[0].src;
		var strs = imgUrl.split("/");
		var imgName = strs[strs.length-1];
	   	if(imgName == 'yes.gif')
	   	{
	   		if(window.confirm('单击“确定”继续[设置为非菜单]操作。单击“取消”停止。'))
		    {
		   		url = url+'value/0/'+Math.random();
		   		$.get(url);
		   		$('#'+id)[0].src = "/images/no.gif";
		   		$('#'+id)[0].alt = "点击设置为菜单";
		    }
	   	}
	   	else
	   	{
	   		if(window.confirm('单击“确定”继续[设置为菜单]操作。单击“取消”停止。'))
	   		{
		   		url = url+'value/1/'+Math.random();
		   		$.get(url);
		   		$('#'+id)[0].src = "/images/yes.gif";
		   		$('#'+id)[0].alt = "点击设置为非菜单";
	   		}
	   	}
	}
	else
	{}
}
<!--
var imgPlus = new Image();
imgPlus.src = "/images/menu_plus.gif";

/**
 * 折叠分类列表
 */
function rowClicked(obj)
{
  obj = obj.parentNode.parentNode;

  var tbl = document.getElementById("list-table");
  var lvl = parseInt(obj.className);
  var fnd = false;

  for (i = 0; i < tbl.rows.length; i++)
  {
      var row = tbl.rows[i];

      if (tbl.rows[i] == obj)
      {
          fnd = true;
      }
      else
      {
          if (fnd == true)
          {
              var cur = parseInt(row.className);
              if (cur > lvl)
              {
                  row.style.display = (row.style.display != 'none') ? 'none' : (Browser.isIE) ? 'block' : 'table-row';
              }
              else
              {
                  fnd = false;
                  break;
              }
          }
      }
  }

  for (i = 0; i < obj.cells[0].childNodes.length; i++)
  {
      var imgObj = obj.cells[0].childNodes[i];
      if (imgObj.tagName == "IMG" && imgObj.src != '/images/menu_arrow.gif')
      {
          imgObj.src = (imgObj.src == imgPlus.src) ? '/images/menu_minus.gif' : imgPlus.src;
      }
  }
}
/**
 * 页面样式js
 */
if (document.getElementById("listDiv"))
{
  document.getElementById("listDiv").onmouseover = function(e)
  {
    obj = Utils.srcElement(e);

    if (obj)
    {
      if (obj.parentNode.tagName.toLowerCase() == "tr") row = obj.parentNode;
      else if (obj.parentNode.parentNode.tagName.toLowerCase() == "tr") row = obj.parentNode.parentNode;
      else return;

      for (i = 0; i < row.cells.length; i++)
      {
        if (row.cells[i].tagName != "TH") row.cells[i].style.backgroundColor = '#F4FAFB';
      }
    }

  }

  document.getElementById("listDiv").onmouseout = function(e)
  {
    obj = Utils.srcElement(e);

    if (obj)
    {
      if (obj.parentNode.tagName.toLowerCase() == "tr") row = obj.parentNode;
      else if (obj.parentNode.parentNode.tagName.toLowerCase() == "tr") row = obj.parentNode.parentNode;
      else return;

      for (i = 0; i < row.cells.length; i++)
      {
          if (row.cells[i].tagName != "TH") row.cells[i].style.backgroundColor = '#FFF';
      }
    }
  }
}
$(document).ready(function() {
var tbl = document.getElementById("list-table");
for (i = 0; i < tbl.rows.length; i++)
{
    var row = tbl.rows[i];
    var cur = parseInt(row.className);
    if (cur != 0 && row.className !='')
    {
        row.style.display = 'none';
    }
}
});
//-->